#!/usr/bin/env bash

# https://minikube.sigs.k8s.io/docs/start/

echo 需要提前安装Docker

sudo mkdir -p /opt/minikube && cd $_ && sudo chmod a+rwx `(pwd)`

curl -LO https://storage.googleapis.com/minikube/releases/latest/minikube-linux-amd64
sudo install minikube-linux-amd64 /usr/local/bin/minikube


# https://www.jianshu.com/p/7a93a8d2a2c8
minikube delete
minikube start --driver=docker \
    --image-mirror-country=cn \
    --iso-url=https://kubernetes.oss-cn-hangzhou.aliyuncs.com/minikube/iso/minikube-v1.16.0.iso \
    --registry-mirror=http://f1361db2.m.daocloud.io

minikube kubectl -- get pods -A
alias kubectl="minikube kubectl --"
minikube dashboard

